//
//  UIView+Load.h
//  LenovoClub
//
//  Created by LQiyue on 2017/10/13.
//  Copyright © 2017年 qiyue. All rights reserved.
//

typedef NS_ENUM(NSInteger, LoadEmptyType)
{
    LoadEmptyType_NoData = 1,
    LoadEmptyType_NetError,
    LoadEmptyType_DataFailed,
    LoadEmptyType_NoData_BGColor,
    LoadEmptyType_Cart,
};

@class LoadEmptyView;

@interface UIView (Load)
@property (nonatomic, strong) LoadEmptyView *emptyView;
- (void)configWithEmptyType:(LoadEmptyType)emptyType emptyBtnBlock:(void(^)(id sender))block;
- (void)configWithEmptyType:(LoadEmptyType)emptyType hasError:(BOOL)hasError imageName:(NSString *)imageName tip:(NSString *)tip btnTitle:(NSString *)btnTitle emptyBtnBlock:(void(^)(id sender))block;
- (void)configWithEmptyType:(LoadEmptyType)emptyType hasError:(BOOL)hasError imageName:(NSString *)imageName tip:(NSString *)tip btnTitle:(NSString *)btnTitle emptyViewTop:(CGFloat)top bgColorStr:(NSString *)bgColorStr emptyBtnBlock:(void(^)(id sender))block;
- (void)removeEmptyView;

@end

@interface LoadEmptyView : UIView
@property (nonatomic, copy) void(^reloadEmptyBtnBlock)(id sender);
- (void)configWithEmptyType:(LoadEmptyType)emptyType emptyBtnBlock:(void(^)(id sender))block;
- (void)configWithEmptyType:(LoadEmptyType)emptyType hasError:(BOOL)hasError imageName:(NSString *)imageName tip:(NSString *)tip btnTitle:(NSString *)btnTitle emptyBtnBlock:(void(^)(id sender))block;
- (void)removeEmptyView;

@end
